Skip to content

Optional parameter to specify preferred editor#1963

Closed
technocidal wants to merge 2 commits intonikitabobko:mainfrom
technocidal:main
Closed

Optional parameter to specify preferred editor#1963
technocidal wants to merge 2 commits intonikitabobko:mainfrom
technocidal:main

Conversation

@technocidal
Copy link
Copy Markdown

Give users the option to explicitly set an editor instead of relying on the automatic behavior. There are scenarios where users have different editors for different purposes e.g. Visual Studio Code for actual projects and Textastic for small configuration files.

PR checklist

  • Explain your changes in the relevant commit messages rather than in the PR description. The PR description must not contain more information than the commit messages (except for images and other media).
  • Each commit must explain what/why/how and motivation in its description. https://cbea.ms/git-commit/
  • Don't forget to link the appropriate issues/discussions in commit messages (if applicable).
  • Each commit must be an atomic change (a PR may contain several commits). Don't introduce new functional changes together with refactorings in the same commit.
  • ./run-tests.sh exits with non-zero exit code. test.log
  • Avoid merge commits, always rebase and force push.

Failure to follow the checklist with no apparent reasons will result in silent PR rejection.

Give users the option to explicitly set an editor instead of relying on
the automatic behavior. There are scenarios where users have different
editors for different purposes e.g. Visual Studio Code for actual
projects and Textastic for small configuration files.

func getTextEditorToOpenConfig() -> URL {
NSWorkspace.shared.urlForApplication(toOpen: findCustomConfigUrl().urlOrNil ?? defaultConfigUrl)?
@MainActor func getTextEditorToOpenConfig() -> URL {
Copy link
Copy Markdown
Author

@technocidal technocidal Feb 16, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(question) Moving this to @MainActor is probably not a big deal (e.g. this function isn't constantly called, other functions in this same file that are used to populate the menubar are already annotated with @MainActor etc.), but it's the most significant change from a runtime perspective so I wanted to point it out.

@nikitabobko
Copy link
Copy Markdown
Owner

I am against adding a config option for such minor use case. You are overconfiguring

@technocidal
Copy link
Copy Markdown
Author

technocidal commented Feb 17, 2026

Makes sense! I'll take your suggestion to heart and if I still want this down the road, I can always just setup an automated workflow somewhere to have a patched version.

AeroSpace has made my Mac so much more enjoyable. Thank you for building it!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants